home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: boeing.comp.unix,comp.lang.c,comp.lang.c++,comp.sources.wanted
- Path: in2.uu.net!bcstec!waetzig
- From: waetzig@bcstec.ca.boeing.com (Todd Waetzig)
- Subject: regular expression matching source code
- Message-ID: <DMwHzn.LIF@bcstec.ca.boeing.com>
- Organization: The Boeing Company
- Distribution: na
- Date: Sat, 17 Feb 1996 03:35:46 GMT
-
- I am looking for the 'C' or 'C++' source for a function to
- perform a match of a string. This function would
- use the syntax of regular expressions. This regular
- expression matching would be similar to that used by
- grep and sed.
-
- Ideally it would look something like
-
- if (match("^1([A-Z]*|[0-9]*)Z?",string_to_search) == 0)
- printf("match found ");
-
- this would match a string_to_search if it
- began with a digit 1
- followed by any number of occurences of uppercase letters
- or by any number of occurrences of digits
- followed by zero or one occurrence of the letter Z
-
- Thanks,
-
- --
- Todd Waetzig Programmer/Analyst Boeing Computer Services
- waetzig@bcstec.ca.boeing.com
-